#include <d3dx9.h>

#include "Game.h"
#include "Sprite.h"
#include "Global.h"
#include "Camera.h"
#include "LoadBackground.h"

class CSimon: public CGame
{
public:
	CSimon(int _nCmdShow);
	~CSimon();

		// IMPORTANT: This is only a SAMPLE, in real game, this should go to a separate class!!!
	int simon_x;		// position of mario
	int simon_y;	

	int world_width;
	int world_height;

	float simon_vx;		// velocity of mario
	float simon_vy;		

	float simon_vx_last;  // last vx of mario before stop ( to determine the direction of mario )

	DWORD last_time;	 // this is to control the animate rate of mario

	LPDIRECT3DSURFACE9 Background;

	CLoadBackground *background;
	CSprite *simon;
	//CAllObject *all;
	CCamera *camera;
protected:
	LPDIRECT3DSURFACE9 _Background;

	virtual void RenderFrame(LPDIRECT3DDEVICE9 d3ddv, int t);
	virtual void ProcessInput(LPDIRECT3DDEVICE9 d3ddv, int Delta);
	virtual void LoadResources(LPDIRECT3DDEVICE9 d3ddv);

	virtual void OnKeyDown(int KeyCode);
};